package cn.bdqn.service.impl;

import cn.bdqn.mapper.VehicleComplaintsMapper;
import cn.bdqn.pojo.VehicleComplaints;
import cn.bdqn.service.VehicleComplaintsService;
import cn.bdqn.utils.RedisUtil;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;

@Service
public class VehicleComplaintsServiceImpl implements VehicleComplaintsService{
    @Resource
    VehicleComplaintsMapper vehicleComplaintsMapper;

    @Resource
    RedisUtil redisUtil;

    @Override
    public List<VehicleComplaints> selectAll(Long brandId) {

        return vehicleComplaintsMapper.selectList(brandId);
    }
    @Transactional
    @Override
    public int insert(VehicleComplaints veh) {

        return vehicleComplaintsMapper.insert(veh);
    }
    @Transactional
    @Override
    public int updateStatus(VehicleComplaints veh) {
        return vehicleComplaintsMapper.updateStatus(veh);
    }


}
